package cn.edu.sdjzu.xg.eagle.Service;

import cn.edu.sdjzu.xg.eagle.entity.Department;
import cn.edu.sdjzu.xg.eagle.exception.BaseException;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.Collection;

public interface DepartmentDaoService {

    Department findDepartment(Long id) throws SQLException, BaseException;

    Collection<Department> findDepartments() throws SQLException, BaseException;

    boolean addDepartment(Connection connection, Department department) throws SQLException, BaseException;

    boolean updateDepartment(Connection connection, Department department) throws SQLException, BaseException;

    boolean deleteDepartment(Integer id) throws SQLException, BaseException;
}
